.ud-sidebar {
  display: flex;
  flex-direction: column;
  width: 180px;
  min-width: 180px;
  flex-shrink: 0;
  background: #eaedf2;
  transition: all 0.2s ease;

  &.collapse {
    width: 0;
    min-width: 0;
    overflow: hidden;
  }

  .ud-sidebar-title {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 40px;
    text-align: center;
    font-size: 14px;
    border-bottom: 1px solid #D9DEE4;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    flex-shrink: 0;
  }

  .ud-sidebar-body {
    flex: 1;
    overflow: auto;
    overflow-x: hidden;
    overflow-y: auto;
  }

  .ud-sidebar-footer {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 15px;
    border-top: 1px solid #D9DEE4;
  }
}

.ud-sidebar-collapse {
  cursor: pointer;
  width: 50px;
  height: 50px;
  position: absolute;
  top: 45%;
  left: calc(180px - 50px);
  transition: all 0.2s ease;
  z-index: 98;

  .ud-sidebar-collapse-bg {
    width: 100%;
    height: 100%;
    border-bottom: 12px solid transparent;
    border-left: none;
    border-right: 13px solid #D9DEE4;
    border-top: 12px solid transparent;
    transition: all 0.2s ease;

    .icon {
      position: absolute;
      right: 0;
      top: 18px;
      font-size: 14px;
      font-weight: bold;
    }
  }

  &:hover {
    .ud-sidebar-collapse-bg {
      border-bottom: 12px solid transparent;
      border-left: none;
      border-right: 20px solid #D9DEE4;
      border-top: 12px solid transparent;
    }
  }

  &.collapse {
    left: 0;

    .ud-sidebar-collapse-bg {
      border-bottom: 12px solid transparent;
      border-left: 14px solid #D9DEE4;
      border-right: none;
      border-top: 12px solid transparent;

      .icon {
        position: absolute;
        left: -36px;
        top: 18px;
        font-weight: bold;
      }
    }

    &:hover {
      .ud-sidebar-collapse-bg {
        border-bottom: 12px solid transparent;
        border-left: 20px solid #D9DEE4;
        border-right: none;
        border-top: 12px solid transparent;
      }
    }
  }
}